<?
define('_VIEW_MODEL_','default');
require_once './init.php';
header("Content-type:text/vnd.wap.wml;charset=utf-8");
$id=intval($id);
$stip = "";
$username = $db->GetRow("select `name` from {$telper}user where `id` = '$id'");
if(isset($act)&&$act=="addcontent"){
$novelid = $db->GetRow("select `id` from {$telper}novel_author where `author` = '$name'");
	if(!empty($novelid)){
		$stip = "用户名重复,请重新输入!";
	}else{
		$rs = $db->Execute("insert into {$telper}novel_author set `author` = '$name',`userid` = '$id'");
		$nu = $db->insert_ID();
		header("Location:authorpage.php?id=$id&auid=$nu");
		exit;
	}
}
$smartyObj->assign("id",$id);
$smartyObj->assign("stip",$stip);
$smartyObj->assign("name",$username['name']);
$smartyObj->display("applaction.tpl");
?>